#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time    : 2021/7/26 11:36
# @Author  : ldh

from basic.device.Android import Android
from commen.page.agx.AGXMyPage import AGXMyPage

class AGXLoginPage(Android):

    inputPhoneNum="cn.cloudbae.loveguangxi:id/etInputPhoneNum" #输入手机号框
    inputPwd="cn.cloudbae.loveguangxi:id/etInputPwd" #输入密码框
    loginBtm="cn.cloudbae.loveguangxi:id/tvLogin" #【登录】


    #账号+密码登录
    @classmethod
    def loginByPwd(cls,phoneNumber,pwd):
        AGXMyPage.openMyPage()
        AGXMyPage.openLoginPage()
        print("选择账号密码登录")
        cls.poco(text="账号密码登录").click()
        cls.poco(cls.inputPhoneNum).set_text(phoneNumber)
        cls.poco(cls.inputPwd).set_text(pwd)
        cls.poco(cls.loginBtm).wait(3).click()




